'''
Created on 23. vel. 2011.

@author: Ana Banana
'''

class Network:
    '''
    represents a network loaded using xml parser
    '''
    nodes = {} #dictionary
    edges = []


    def __init__(self, name):
        self.name = name
        
    def addNode(self, node):
        print node.getId();
        if node.getIdRef() in self.nodes.keys():
            print self.nodes[node.getIdRef()];
        self.nodes[node.getIdRef()] = node
        
    def addEdge(self, edge):
        self.edges.append(edge)
        
    def getNodes(self):
        return self.nodes
    
    def getEdges(self):
        return self.edges
        